@import 'mixins';

* {
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -webkit-tap-highlight-color: transparent;
}

*,
*:before,
*:after {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
}

body, html {
  height: 100%;
  width: 100%;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, "Pingfang SC", "Microsoft Yahei", "WenQuanYi Micro Hei", sans-serif;
}

html.overflow-hidden, html.overflow-hidden body {
  height: 100%;
  overflow: hidden;
}

img {
  max-width: 100%;
}

.pull-right {
  float: right !important;
}

.pull-left {
  float: left !important;
}

.text-left {
  text-align: left !important;
}

.m-b {
  margin-bottom: $space-sm !important;
}

.m-t {
  margin-top: $space-sm !important;
}

.weui-icon-success {
  color: $color-success;
}

.weui-btn-area {
  margin: 1.17647059em .3rem .3em;
}

.weui-btn {
  font-size: .32rem;
  @include border-radius(.06rem);
}

.weui-btn_primary {
  background-color: $color-info;

  &:not(.weui-btn_disabled):active {
    background-color: darken($color-info, 5);
  }
}

//weui-reset
.weui-picker-modal {
  height: auto;

  .picker-items {
    font-size: .3rem;
  }

  .picker-modal-inner {
    height: 4.32rem;
  }
}

.weui-select-modal .weui_cells {
  max-height: 4.32rem;
}

.toolbar {
  font-size: .32rem;

  .toolbar-inner {
    height: .88rem;
  }

  .picker-button {
    height: .88rem;
    line-height: .88rem;
  }

  .title {
    line-height: .88rem;
    font-size: .32rem;
  }
}

.weui-picker-modal {
  height: 5.2rem;

  .picker-items {
    font-size: .28rem;
  }

  .picker-modal-inner {
    height: 4.32rem;
  }
}

.picker-calendar-month-picker, .picker-calendar-year-picker {
  line-height: .88rem;
}

.picker-calendar-month-picker .current-month-value, .picker-calendar-year-picker .current-month-value, .picker-calendar-month-picker .current-year-value, .picker-calendar-year-picker .current-year-value {
  height: .88rem;
}

.picker-calendar-month-picker a.icon-only, .picker-calendar-year-picker a.icon-only {
  height: .88rem;
  line-height: .78rem;
}

.picker-calendar-week-days {
  height: .36rem;
  font-size: .22rem;

  .picker-calendar-week-day {
    line-height: .36rem;
  }

  & + .picker-calendar-months {
    height: 4.76rem;
  }
}

.swiper-wrapper {
  img {
    width: 100%;
    display: block;
  }
}

.weui-cell {
  padding: .2rem .3rem;
}

.weui-cell_link {
  font-size: $fz-sm;
  color: $color-normal;
}

.weui-panel__ft {
  .weui-cell_link {
    font-size: $fz-xs;
    color: $color-lighter;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;

    i {
      position: relative;
      top: -1px;
      vertical-align: middle;
      font-size: .32rem;
      color: $color-info;
      margin-right: .1rem;
    }
  }
}

.weui-cells {
  margin-top: 0;
  font-size: $fz-sm;

  .weui-cell__hd {
    i {
      margin-right: .1rem;
      font-size: $fz-larger;
      color: $color-info;
    }
  }
}

.weui-cell_access {
  .weui-cell__ft:after {
    width: 10px;
    height: 10px;
    border-width: 1px 1px 0 0;
  }
}

.weui-select {
  height: .4rem;
  line-height: .4rem;
  text-align: right;
}

.weui-cell_select {
  .weui-cell__bd:after {
    width: 10px;
    height: 10px;
    border-width: 1px 1px 0 0;
  }
}

.weui-media-box_text {
  .weui-media-box__desc {
    margin: 0;
    font-size: .26rem;
    line-height: 1.6;
    -webkit-line-clamp: inherit;
  }
}

i.icon.icon-next, i.icon.icon-prev {
  width: .3rem;
  height: .3rem;
}

.tabbar {
  position: fixed;
  left: 0;
  bottom: 0;
  height: .88rem;
  width: 100%;
  box-sizing: border-box;
  font-size: .34rem;
  margin: 0;
  z-index: 99;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  background-color: #ffffff;

  .tabbar-inner {
    width: 100%;
    height: 100%;
    padding: 0 .5rem;
    @include flexbox();
    @include justify-content(space-between);
    @include align-items(center);
  }

  .link-bar {
    position: relative;
    color: #a3a1a0;
    line-height: 1;
    text-align: center;
    overflow: visible;

    &.has-notice {
      &:before {
        content: '';
        position: absolute;
        right: 0;
        top: 0;
        width: .16rem;
        height: .16rem;
        background-color: $color-danger;
        @include border-radius(50%);
      }
    }

    &.active {
      color: $color-info;
    }

    & > i {
      display: inline-block;
      font-size: .4rem;
      padding: 0 .2rem;
    }

    & > span {
      margin-top: .04rem;
      display: block;
      font-size: .24rem;
      padding: 0 .2rem;
    }
  }
}

.weui-pull-to-refresh__layer {
  height: auto;
}

.view {
  box-sizing: border-box;
  height: 100%;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  @include background-size(cover);
  background-color: #f8f8f8;

  &.lock {
    overflow: hidden;
  }

  &.has-navbar {
    padding-top: .88rem;
  }

  &.has-tabbar {
    padding-bottom: .88rem;
  }
}

.filter-wrap {
  position: absolute;
  top: .88rem;
  left: 0;
  width: 100%;
  z-index: 1;
  background-color: #efeff4;

  .filter-ul {
    @include flexbox();
    list-style: none;
    li {
      @include flex(1);
      text-align: center;
      line-height: .52rem;
      font-size: .24rem;
      a{
        position: relative;
        color: #333333;
        &:before{
          content: '';
          position: absolute;
          right: -.26rem;
          top: .08rem;
          border-bottom: .07rem solid #666;
          border-left: .07rem solid transparent;
          border-right: .07rem solid transparent;
        }
        &:after{
          content: '';
          position: absolute;
          right: -.26rem;
          bottom: .04rem;
          border-top: .07rem solid #666;
          border-left: .07rem solid transparent;
          border-right: .07rem solid transparent;
        }
      }
      &.up{
        a{
          color: #ff6c0b;
          &:before{
            border-bottom-color: #ff6c0b;
          }
        }
      }
      &.down{
        a{
          color: #ff6c0b;
          &:after{
            border-top-color: #ff6c0b;
          }
        }
      }
    }
  }
  &+.has-navbar{
    padding-top: 1.2rem;
  }
}

.header {
  position: absolute;
  right: 0;
  left: 0;
  top: 0;
  z-index: 100;
  height: .88rem;
  @include flexbox();

  .header-left {
    .city-select {
      display: block;
      padding-left: .2rem;
      height: .88rem;
      line-height: .88rem;
      text-align: center;
      font-size: .24rem;
      color: $color-normal;
      vertical-align: middle;

      i {
        font-size: .24rem;
      }
    }
  }

  .search-wrap {
    @include flex(1);

    .weui-search-bar {
      padding: .16rem .2rem;

      &:before {
        display: none;
      }
    }

    .weui-search-bar__form {
      @include border-radius(.26rem);
      background-color: transparent;

      &:after {
        border-color: #ffffff;
      }
    }

    .weui-search-bar__cancel-btn {
      margin-left: .2rem;
      line-height: .56rem;
      font-size: .28rem;
      color: $color-light;
    }

    .weui-search-bar__box {
      padding-left: .6rem;
      padding-right: .6rem;

      .weui-icon-search {
        left: .2rem;
        line-height: .56rem;
      }

      .weui-search-bar__input {
        padding: .08rem 0;
        height: 1.42857143em;
        font-size: .28rem;
      }

      .weui-icon-clear {
        padding: 0 .2rem;
        line-height: .56rem;
      }

    }

    .weui-search-bar__label {
      border-radius: .06rem;

      &:after {
        display: none;
      }
    }

    .weui-icon-clear, .weui-icon-search {
      font-size: .28rem;
    }

    .weui-search-bar__label {
      .weui-icon-search {
        margin-right: .1rem;
        line-height: .54rem;
      }

      span {
        line-height: .54rem;
        font-size: .28rem;
      }
    }

    &.normal-search {
      .weui-search-bar {
        background-color: #f8f8f8;
        @include opacity(1);
      }
    }
  }

}

.login-header {
  text-align: center;
  padding-top: 2rem;

  dt {
    color: #e2415c;
    font-weight: bold;
    font-size: .6rem;
  }

  dd {
    font-size: .28rem;
    color: #333333;
  }
}

.login-wrap {
  height: 100%;
  background: url(../images/login-wrap.jpg) top center no-repeat;
  @include background-size(cover);

  .login-box {
    margin: .4rem .7rem .2rem;
    background-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 3px rgba(0, 0, 0, 0.1);
    padding: .6rem;
    @include border-radius(.1rem);

    .weui-cell {
      font-size: .2rem;
      border: 1px solid #dedede;
      padding: .05rem;
      background-color: #ffffff;
      @include border-radius(1px);

      i {
        font-size: .26rem;
        margin: 0 .2rem;
        color: #dcdcdc;
      }

      .weui-input {

      }

      .weui-select {
        padding-left: 0;
        width: 100%;
        border: 0;
        outline: 0;
        -webkit-appearance: none;
        background-color: transparent;
        font-size: inherit;
        color: inherit;
        height: 1.47058824em;
        line-height: 1.47058824;
      }

      & + .weui-cell {
        margin-top: .2rem;

        &:before {
          display: none;
        }
      }
    }

    .weui-btn-area {
      margin: .2rem 0 0;

      .weui-btn_primary {
        font-size: .24rem;
        background-color: #207bd8;
        @include border-radius(1px);
        color: #ffffff;

        &:after {
          @include border-radius(1px);
        }
      }
    }

    .weui-agree {
      padding-left: 0;
    }
  }
}

.choose-wrap {
  height: 100%;
  background: url(../images/choise.jpg) center no-repeat;
  @include background-size(cover);
  @include flexbox();
  @include flex-direction(column);

  .choose-btn {
    @include justify-content(center);
    @include flexbox();
    @include align-items(center);
    @include flex(1);
    font-size: .9rem;
    color: #ffffff;
    font-weight: bold;
    text-shadow: 2px 2px #333;
  }
}

.circums-wrap {
  padding: $space-sm;

  .circums-list {
    list-style: none;

    & > a {
      display: block;
      position: relative;
      padding: 0 $space-sm;
      background-color: #ffffff;
      color: #333333;

      .circums-link {
        display: block;
      }

      .navigation-box {
        position: absolute;
        top: .2rem;
        right: .2rem;
        text-align: center;
        color: $color-info;
        font-size: .24rem;

        span {
          display: block;
        }

        i {
          font-size: .28rem;
          line-height: 1;
          display: block;
        }
      }

      & + a {
        margin-top: $space-sm;
      }

      .circums-list-a {
        padding-top: $space-xs;
        font-size: $fz-normal;

        strong {
          font-weight: normal;
          padding-right: .1rem;
          display: inline-block;
        }

        small {
          line-height: .5rem;
          font-size: .24rem;
        }
      }

      .circums-location {
        padding-bottom: .1rem;
        color: $color-lighter;
        font-size: $fz-xs;

        i {
          font-size: inherit;
        }
      }

      .circums-footer {
        font-size: $fz-xs;
        padding: $space-xs 0;

        .tag {
          float: right;
        }

        span {
          & + span {
            margin-right: $space-xs;
          }
        }
      }

      .circums-tab {
        margin: 0 -.2rem;
        font-size: .24rem;
        @include flexbox();

        .tab-link {
          @include flex(1);
          text-align: center;
          padding: .1rem;
        }
      }
    }
  }
}

.my-panel {
  margin-top: $space-sm !important;
  display: block;

  .weui-form-preview {
    &:before {
      display: none;
    }
  }
}

.weui-form-preview__value {
  color: #333333;
}

.weui-panel__hd {
  padding: .2rem .3rem .1rem;
  font-size: .32rem;
  color: $color-normal;

  a {
    color: $color-normal;
  }

  em {
    &.pull-right {
      padding-top: 0;
      font-size: .28rem;
      color: $color-danger;
    }
  }

  .pull-right {
    padding-top: .1rem;
    font-size: .24rem;
    color: $color-info;
  }
}

.history-list {
  margin-top: .2rem;

  .weui-panel__hd {
    font-size: .28rem;
  }

  .weui-panel__ft {
    text-align: right;
    padding: .2rem;

    .weui-btn {
      vertical-align: top;
    }
  }

  .my-preview {
    display: block;

    .weui-form-preview__bd {
      font-size: .24rem;
    }
  }
}

.info-panel {
  background: url(../images/change-header.jpg) center no-repeat;
  background-size: cover;
  color: #ffffff;

  &:before {
    display: none;
  }

  .weui-media-box__title {
    font-weight: bold;
    font-size: .34rem;
  }

  .desc {
    color: #ffffff;
  }
}

.doctor-panel {
  .weui-media-box_appmsg {
    .weui-media-box__thumb {
      @include border-radius(50%);
    }

    .desc {
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
      font-size: .24rem;
    }

    .statu-tag {
      position: absolute;
      right: .5rem;
      top: 0;
    }
  }

  .user-icon {
    width: .9rem;
    height: .9rem;
    line-height: .9rem;
    text-align: center;
    background-color: $color-info;
    color: #ffffff;
    @include border-radius(50%);
    font-size: .5rem;
    margin-right: .2rem;
  }

  .check {
    font-size: .4rem;
    color: $color-success;
  }
}

.desc {
  color: #aaa;
}